﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Text;

namespace SimpleUnitity.Database
{
    public class ProviderDbTool : DbTool
    {
        public ProviderDbTool(IDbConnection connection, IDbDataAdapter adapter)
            : base(connection, adapter, null)
        {
            this.parameterPrefix = base.ParameterPrefix;
            this.statementPrefix = base.StatementPrefix;
            this.statementSuffix = base.StatementSuffix;
        }

        public ProviderDbTool(IDbConnection connection, IDbDataAdapter adapter, string parameterPrefix, string statementPrefix, string statementSuffix)
            : base(connection, adapter, null)
        {
            this.parameterPrefix = parameterPrefix;
            this.statementPrefix = statementPrefix;
            this.statementSuffix = statementSuffix;
        }

        public string IdentitySQL { get; set; }

        private string parameterPrefix;
        private string statementPrefix;
        private string statementSuffix;

        public override string ParameterPrefix
        {
            get { return parameterPrefix; }
        }

        public override string StatementPrefix
        {
            get { return statementPrefix; }
        }

        public override string StatementSuffix
        {
            get { return statementSuffix; }
        }
    }
}
